
public class Teset {
    public static void main(String[] args) {
        int[] l = new int[]{1,5,-4,9,2,-7};
        int min = 0;
        for (int i = 0; i < l.length; i++) {
            if (l[i] > min) min = l[i];
        }
        System.out.println(min);
    }
}
